﻿<%@ Page Language="C#" CodeBehind="Register.aspx.cs" Inherits="BikeBouncer.Site.Register_aspx" MasterPageFile="/MainLayout.master" %>
<%@ Register TagPrefix="BB" TagName="Ads" Src="/Ads.ascx" %>
<asp:Content ContentPlaceHolderID="MainContents" runat="server">
	<asp:Panel ID="PanForm" runat="server">
		<p>
			<asp:Literal meta:resourcekey="LitIntroduction" runat="server" />
		</p>
		<div class="Panel">
			<h3><asp:Literal meta:resourcekey="LitPanelBike" runat="server" /></h3>
			<div class="PanelForm">
				<asp:Label CssClass="FormLabelRequired" AssociatedControlID="TxtItemTitle" meta:resourcekey="LblItemTitle" runat="server" />
				<asp:TextBox ID="TxtItemTitle" CssClass="FormText" Width="220px" meta:resourcekey="TxtItemTitle" runat="server" />
				<asp:RequiredFieldValidator ID="ReqTxtItemTitle" ControlToValidate="TxtItemTitle" Display="Dynamic" Text="*" meta:resourcekey="ReqTxtItemTitle" runat="server" />
				<br />
				<asp:Label CssClass="FormLabelRequired" AssociatedControlID="TxtItemMaker" meta:resourcekey="LblItemMaker" runat="server" />
				<asp:TextBox ID="TxtItemMaker" CssClass="FormText" Width="220px" meta:resourcekey="TxtItemMaker" runat="server" />
				<asp:RequiredFieldValidator ID="ReqTxtItemMaker" ControlToValidate="TxtItemMaker" Display="Dynamic" Text="*" meta:resourcekey="ReqTxtItemMaker" runat="server" />
				<asp:AutoCompleteExtender ID="AutoComplete_TxtItemMaker" runat="server"
										  ServiceMethod="AutoComplete_Maker"
										  TargetControlID="TxtItemMaker" />
				<br />
				<asp:Label AssociatedControlID="TxtItemSerial" meta:resourcekey="LblItemSerial" runat="server" />
				<asp:TextBox ID="TxtItemSerial" CssClass="FormText" Width="220px" meta:resourcekey="TxtItemSerial" runat="server" />
				<asp:HyperLink ID="LinkSerialTips" NavigateUrl="/Images/BikeSerialWhere.jpg" meta:resourcekey="LinkSerialTips" runat="server"><img src="/Images/Ico/Info24.png" height="24" width="24" alt="?" class="FormRightIcon" /></asp:HyperLink>

				<div id="TipsItemTitle" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitItemTitleTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitItemTitleTipInfo" runat="server" /></p>
					</div>
				</div>
				<div id="TipsItemMaker" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitItemMakerTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitItemMakerTipInfo" runat="server" /></p>
					</div>
				</div>
				<div id="TipsItemSerial" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitItemSerialTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitItemSerialTipInfo" runat="server" /></p>
					</div>
				</div>
				<script type="text/javascript">
					var btItemTitle = jQuery.extend({}, defaultTipOptions);
					var btItemMaker = jQuery.extend({}, defaultTipOptions);
					var btItemSerial = jQuery.extend({}, defaultTipOptions);

					btItemTitle.contentSelector = "$('#TipsItemTitle').html()";
					btItemMaker.contentSelector = "$('#TipsItemMaker').html()";
					btItemSerial.contentSelector = "$('#TipsItemSerial').html()";

					$("input[id$='_TxtItemTitle']").bt(btItemTitle);
					$("input[id$='_TxtItemMaker']").bt(btItemMaker);
					$("input[id$='_TxtItemSerial']").bt(btItemSerial);

					$("a[id$='_LinkSerialTips']").colorbox();
				</script>
			</div>
		</div>
		<div class="Panel">
			<h3><asp:Literal meta:resourcekey="LitPanelStolen" runat="server" /></h3>
			<asp:RadioButton ID="ChkItemNotStolen" GroupName="WasStolen" Checked="true" meta:resourcekey="ChkItemNotStolen" runat="server" />
			<br />
			<asp:RadioButton ID="ChkItemWasStolen" GroupName="WasStolen" meta:resourcekey="ChkItemWasStolen" runat="server" />
			<div id="DivWasStolen" class="PanelForm" style="display:none">
				<p>
					<asp:Literal meta:resourcekey="LitStolenProvideInfo" runat="server" />
				</p>
				<asp:Label AssociatedControlID="TxtNotePostcode" meta:resourcekey="LblNotePostcode" runat="server" />
				<asp:TextBox ID="TxtNotePostcode" CssClass="FormText" Width="220px" meta:resourcekey="TxtNotePostcode" runat="server" />
				<br />
				<asp:Label AssociatedControlID="TxtNoteLocation" meta:resourcekey="LblNoteLocation" runat="server" />
				<asp:TextBox ID="TxtNoteLocation" CssClass="FormText" Width="220px" meta:resourcekey="TxtNoteLocation" runat="server" />
				<br />
				<asp:Label AssociatedControlID="TxtNoteCity" meta:resourcekey="LblNoteCity" runat="server" />
				<asp:TextBox ID="TxtNoteCity" CssClass="FormText" Width="220px" meta:resourcekey="TxtNoteCity" runat="server" />
				<asp:AutoCompleteExtender ID="AutoComplete_TxtNoteCity" runat="server"
										  ServiceMethod="AutoComplete_City"
										  TargetControlID="TxtNoteCity" />
				<br />
				<asp:Label AssociatedControlID="TxtNoteDate" meta:resourcekey="LblNoteDate" runat="server" />
				<asp:TextBox ID="TxtNoteDate" CssClass="FormText" Width="220px" meta:resourcekey="TxtNoteDate" runat="server" />
				<asp:CalendarExtender ID="Calendar_TxtNoteDate" runat="server"
									  TargetControlID="TxtNoteDate" />
				<br />
				<asp:Label AssociatedControlID="TxtNoteDetails" meta:resourcekey="LblNoteDetails" runat="server" />
				<asp:TextBox ID="TxtNoteDetails" CssClass="FormArea" TextMode="MultiLine" Width="300px" Height="80px" meta:resourcekey="TxtNoteDetails" runat="server" />

				<div id="TipsNotePostcode" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitNotePostcodeTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitNotePostcodeTipInfo" runat="server" /></p>
					</div>
				</div>
				<div id="TipsNoteLocation" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitNoteLocationTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitNoteLocationTipInfo" runat="server" /></p>
					</div>
				</div>
				<div id="TipsNoteCity" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitNoteCityTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitNoteCityTipInfo" runat="server" /></p>
					</div>
				</div>
				<div id="TipsNoteDate" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitNoteDateTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitNoteDateTipInfo" runat="server" /></p>
					</div>
				</div>
				<div id="TipsNoteDetails" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitNoteDetailsTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitNoteDetailsTipInfo" runat="server" /></p>
					</div>
				</div>
				<script type="text/javascript">
					var btNoteDate = jQuery.extend({}, defaultTipOptions);
					var btNotePostcode = jQuery.extend({}, defaultTipOptions);
					var btNoteLocation = jQuery.extend({}, defaultTipOptions);
					var btNoteCity = jQuery.extend({}, defaultTipOptions);
					var btNoteDetails = jQuery.extend({}, defaultTipOptions);

					btNoteDate.contentSelector = "$('#TipsNoteDate').html()";
					btNotePostcode.contentSelector = "$('#TipsNotePostcode').html()";
					btNoteLocation.contentSelector = "$('#TipsNoteLocation').html()";
					btNoteCity.contentSelector = "$('#TipsNoteCity').html()";
					btNoteDetails.contentSelector = "$('#TipsNoteDetails').html()";

					$("input[id$='_TxtNoteDate']").bt(btNoteDate);
					$("input[id$='_TxtNotePostcode']").bt(btNotePostcode);
					$("input[id$='_TxtNoteLocation']").bt(btNoteLocation);
					$("input[id$='_TxtNoteCity']").bt(btNoteCity);
					$("input[id$='_TxtNoteDetails']").bt(btNoteDetails);
				</script>
			</div>
		</div>
		<div class="Panel">
			<h3><asp:Literal meta:resourcekey="LitPanelUser" runat="server" /></h3>
			<asp:Panel ID="PanLoginDetails" CssClass="PanelForm" runat="server">
				<p>
					<asp:Literal meta:resourcekey="LitLoginInfo" runat="server" />
				</p>
				<asp:Label CssClass="FormLabelRequired" AssociatedControlID="TxtUserEmail" meta:resourcekey="LblUserEmail" runat="server" />
				<asp:TextBox ID="TxtUserEmail" CssClass="FormText" Width="220px" meta:resourcekey="TxtUserEmail" runat="server" />
				<asp:RequiredFieldValidator ID="ReqTxtUserEmail" ControlToValidate="TxtUserEmail" Display="Dynamic" Text="*" meta:resourcekey="ReqTxtUserEmail" runat="server" />
				<asp:RegularExpressionValidator ID="ValTxtUserEmail" ControlToValidate="TxtUserEmail" Display="Dynamic" Text="*" meta:resourcekey="ValTxtUserEmail" runat="server" />
				<br />
				<asp:Label CssClass="FormLabelRequired" AssociatedControlID="TxtUserPassword" meta:resourcekey="LblUserPassword" runat="server" />
				<asp:TextBox ID="TxtUserPassword" CssClass="FormText" Width="220px" TextMode="Password" meta:resourcekey="TxtUserPassword" runat="server" />
				<asp:RequiredFieldValidator ID="ReqTxtUserPassword" ControlToValidate="TxtUserPassword" Display="Dynamic" Text="*" meta:resourcekey="ReqTxtUserPassword" runat="server" />
				
				<div id="TipsUserEmail" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitUserEmailTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitUserEmailTipInfo" runat="server" /></p>
					</div>
				</div>
				<div id="TipsUserPassword" style="display:none">
					<div class="FormTips">
						<h4><asp:Literal meta:resourcekey="LitUserPasswordTip" runat="server" /></h4>
						<p><asp:Literal meta:resourcekey="LitUserPasswordTipInfo" runat="server" /></p>
					</div>
				</div>
				<script type="text/javascript">
					var btUserEmail = jQuery.extend({}, defaultTipOptions);
					var btUserPassword = jQuery.extend({}, defaultTipOptions);

					btUserEmail.contentSelector = "$('#TipsUserEmail').html()";
					btUserPassword.contentSelector = "$('#TipsUserPassword').html()";

					$("input[id$='_TxtUserEmail']").bt(btUserEmail);
					$("input[id$='_TxtUserPassword']").bt(btUserPassword);
				</script>
			</asp:Panel>
			<asp:Panel ID="PanUserLogged" runat="server">
				<asp:Literal meta:resourcekey="LitLoggedAs" runat="server" />
				<strong><asp:Literal ID="LitLoggedEmail" runat="server" /></strong>.
				<p>
					<asp:Literal ID="LitLoggedName" meta:resourcekey="LitLoggedName" runat="server" />
					<asp:HyperLink NavigateUrl="/Logout.aspx?r=Register.aspx" Font-Bold="true" meta:resourcekey="LinkLogout" runat="server" />
				</p>
			</asp:Panel>
		</div>
		<div class="PanelButtons">
			<asp:ValidationSummary CssClass="ValSummary" DisplayMode="List" ShowSummary="true" HeaderText="<%$ Resources:Messages,ValidationSummary %>" runat="server" />
			<asp:Button ID="ButRegister" CssClass="FormButton" OnClick="ButRegister_Click" meta:resourcekey="ButRegister" runat="server" />
		</div>
	</asp:Panel>
	<asp:Panel ID="PanRegistered" runat="server">
		<div class="Panel">
			<p>
				<asp:Literal meta:resourcekey="LitCongratulations1" runat="server" />
			</p>
			<p>
				<asp:Literal ID="LitCongratsNewUser" meta:resourcekey="LitCongratsNewUser" runat="server" />
			</p>
		</div>
		<div class="Panel">
			<h3><asp:Literal meta:resourcekey="LitWhatsNext" runat="server" /></h3>
			<p>
				<asp:Literal meta:resourcekey="LitWhatsNext1" runat="server" />
			</p>
			<p>
				<asp:Literal meta:resourcekey="LitWhatsNext2" runat="server" />
			</p>
		</div>
	</asp:Panel>
</asp:Content>